﻿using NUnit.Framework;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ATM.BUS;

namespace ATM.UnitTest
{
    [TestFixture()]
    public class TranfserMoneyUT
    {
        private string a = "1";
        private string b = "362";
        private double x1 = 1000000, x2 = 30000000;

        [TestCase]
        public void TestNotAccountReceiveID()
        {
            Assert.AreEqual(CardTransferBUS.CheckAccountReceived_ID(a), true);
        }

        [TestCase]
        public void TestAccountReceiveID()
        {
            Assert.AreEqual(CardTransferBUS.CheckAccountReceived_ID(b), false);
        }

        public bool CheckAmount(double x2)
        {
            double k = CardTransferBUS.Get_Balance(a);
            if (k >= x2) return true;
            return false;
        }
        [TestCase]
        public void TestTrueAmountTranfser()
        {
            bool a = CheckAmount(x1);
            Assert.AreEqual(a, true);
        }

        [TestCase]
        public void TestFalseAmountTranfser()
        {
            bool a = CheckAmount(x2);
            Assert.AreEqual(a, false);
        }


    }
}
